package com.jvxb.manage.livable.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * @author jvxb
 * @since 2022-01-05
 */
@Data
@TableName("assets_agent_host")
public class AssetsAgentHost implements Serializable {


    @TableId(value = "id", type = IdType.AUTO)
    private Long id;
    /**
     * 机器ip
     */
    private String host;
    /**
     * 机器类型
     */
    private String dbType;
    /**
     * 机器所属环境
     */
    private String env;
    /**
     * 机器名称
     */
    private String agentName;
    /**
     * 全部内存
     */
    private Long memoryAll;
    /**
     * 使用内存
     */
    private Long memoryUsed;
    /**
     * 空闲内存
     */
    private Long memoryFree;
    /**
     * 全部硬盘
     */
    private Long diskAll;
    /**
     * 使用硬盘
     */
    private Long diskUsed;
    /**
     * 空闲硬盘
     */
    private Long diskFree;
    /**
     * 机房信息
     */
    private String idcCode;
    /**
     * 上报途径（system|agent）
     */
    private String reportType;
    /**
     * 主机类型（phy:物理机|vm:虚拟机|rds:云主机）
     */
    private String hostType;
    /**
     * 锁定状态 0否 1是
     */
    private Integer isLock;
    /**
     * 初始化状态 0否 1是
     */
    private Integer isInit;
    /**
     * 初始化版本
     */
    private String initVersion;
    /**
     * 可支持部署实例数
     */
    private Integer supportInsNum;
    /**
     * 已部署实例数
     */
    private Integer existsInsNum;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    public static final String ID = "id";

    public static final String HOST = "host";

    public static final String DBTYPE = "db_type";

    public static final String AGENT_NAME = "agent_name";

    public static final String MEMORY_ALL = "memory_all";

    public static final String MEMORY_USED = "memory_used";

    public static final String MEMORY_FREE = "memory_free";

    public static final String DISK_ALL = "disk_all";

    public static final String DISK_USED = "disk_used";

    public static final String DISK_FREE = "disk_free";

    public static final String IDC_CODE = "idc_code";

    public static final String REPORT_TYPE = "report_type";

    public static final String HOST_TYPE = "host_type";

    public static final String IS_LOCK = "is_lock";

    public static final String IS_INIT = "is_init";

    public static final String INIT_VERSION = "init_version";

    public static final String SUPPORT_INS_NUM = "support_ins_num";

    public static final String EXISTS_INS_NUM = "exists_ins_num";

    public static final Integer LOCK_STATU = 1;

    public static final Integer UNLOCK_STATU = 0;

    public static final Integer INIT_STATU = 1;

    public static final Integer UNINIT_STATU = 0;

    public static final String UPDATE_TIME = "update_time";

    public static final String CREATE_TIME = "create_time";

    private static final long serialVersionUID = 6783451729851495576L;
}
